<template>
    <AppView :title="title" :menu-list="testMenuListData">
      <div slot="content">
        <router-view/>
      </div>
    </AppView>
</template>

<script>
import AppView from "../../components/basic/AppView";
import caishen from "../../assets/image/caishen.png";

export default {
  name: 'Home',
  components: {
    AppView
  },
  data: function () {
    return {
      title: "",
      testMenuListData: {
        baseRoute: "test",
        menuList: [
          {
            title: "财务管理",
            icon: caishen,
            items: [
              {
                route: "",
                text: "充值记录",
                default: true
              },
              {
                route: "a1",
                text: "提现记录"
              },
              {
                route: "a2",
                text: "提现审核"
              },
              {
                route: "a3",
                text: "提现处理"
              },
            ]
          },
          {
            title: "资金管理",
            icon: caishen,
            items: [
              {
                route: "a1",
                text: "用户资金"
              },
              {
                route: "a3",
                text: "还款记录"
              }
            ]
          }
        ]
      }
    }
  },
  methods: {
    onClick(event, pIndex, index) {
      this.title = this.testMenuListData[pIndex].items[index].text;
      console.log(this.title);
    }
  }
}
</script>

<style scoped>
</style>
